from ultralytics import YOLO

model = YOLO('yolov8n.pt')

# 开始评估，使用保存的参数
metrics = model.val()

print(metrics)
metrics.box.map    # map50-95
metrics.box.map50  # map50
metrics.box.map75  # map75
metrics.box.maps   # a list contains map50-95 of each category
